const components = {};

const requireAll = (context) =>
    context.keys().map((item) => context(item).default);
const files = require.context("./modules", false, /\.jsx$/);
requireAll(files).forEach((file) => {
    components[file.name] = file;
});

module.exports = components;
